package com.hyg.lib_common.ui.activity;

import android.os.Bundle;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import com.hyg.lib_base.mainUtils.StatusBarUtil;
import com.hyg.lib_common.Base.BaseActivity;
import com.hyg.lib_common.R;

public class TesttingSelfIntroActivity extends BaseActivity {
    TextView titleTv;
    ImageView contentIV;
    TextView contentTv, numbersTv;


    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_testting_self_intro);
        StatusBarUtil.setStatusBar(1, this, getResources().getColor(R.color.white), 60, null, null, true);
        init();
    }

    public void init() {
        String type = getIntent().getStringExtra("type");
        titleTv = findViewById(R.id.tv_title);
        contentIV = findViewById(R.id.tv_showimage);
        contentTv = findViewById(R.id.tv_content);
        numbersTv = findViewById(R.id.tv_test_numbers);
        titleTv.setText(type);

        switch (type) {
            case "体质辨识完整版":
            case "体质辨识简易版":
                contentIV.setImageResource(R.mipmap.self_tizhi_icon);
                contentTv.setText(getResources().getString(R.string.self_tizhi_intro));
                numbersTv.setText("100+");
                break;
            case "抑郁辨识":
                contentIV.setImageResource(R.mipmap.self_tizhi_icon);
                contentTv.setText(getResources().getString(R.string.self_yiyu_intro));
                numbersTv.setText("101+");
                break;
            case "焦虑辨识":
                contentIV.setImageResource(R.mipmap.self_tizhi_icon);
                contentTv.setText(getResources().getString(R.string.self_jiaolv_intro));
                numbersTv.setText("101+");
                break;
            case "失眠检测":
                contentIV.setImageResource(R.mipmap.self_tizhi_icon);
                contentTv.setText(getResources().getString(R.string.self_shimian_intro));
                numbersTv.setText("101+");
                break;
            case "心里压力测试":
                contentIV.setImageResource(R.mipmap.self_tizhi_icon);
                contentTv.setText(getResources().getString(R.string.self_yali_intro));
                numbersTv.setText("101+");
                break;
            case "疲劳辨识":
//                titleTv.setImageResource(R.mipmap.self_tizhi_icon);
//                contentTv.setText(getResources().getString(R.string.self_jiaolv_intro));
//                numbersTv.setText("101+");
                break;
        }


    }


    public void onBack(View view) {
        finish();
    }


}